import request from '@/utils/request'

// 查询企业的部门列表
export const getDepartmentInfoRequest = params => request.get('/company/department', { params })

// 新增子部门接口
export const addDepartmentRequest = data => request.post('/company/department', data)

// 获取部门详细信息 (编辑功能数据回显)
export const getDepartmentDetailRequest = id => request.get(`/company/department/${id}`)

// 修该部门详细信息
export const updateDepartmentRequest = data => request.put(`/company/department/${data.id}`, data)

// 删除部门
export const deleteDepartmentRequest = id => request.delete(`/company/department/${id}`)
